<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>大麦网</title>
	<link rel="stylesheet" href="css/homepage.css">
	<link rel="stylesheet" href="css/barley.css">
	<link rel="shortcut icon" href="imgs/favicon.ico"/>
	<script src="js/jquery3.min.js"></script>
	<script src="js/barley.js"></script>

</head>
<body>
	<!-- 头部导航 -->
	<div class="navigation_warp">
		<div class="navigation_nav">
			<div class="nav_left">
				<img src="imgs/barley.png" alt="barley">
				
				<div class="nationwide">
					<span class="landmark">
						<img src="imgs/landmark.png" alt="landmark">
					</span>
					<a href="#">全国</a>
					<span class="subscript">
						<img src="imgs/subscript.png" alt="">
					</span>
					<!-- 二级菜单 -->
					<div class="nationwide_city">
						<span class="bignum_img"><img src="imgs/bignum.png" alt="大于号"></span>
						<div class="present_tow">
							<span class="title_city">当前城市：</span>
							<p class="above">
								
								<span class="all_city">		全国			
								</span>

							</p>
							<span class="title_city">热门城市：</span>
							<p class="above aboves">								
								<span>全国</span>
								<span>北京</span>
								<span>上海</span>
								<span>深圳</span>
								<span>广州</span>
								<span>杭州</span>
								<span>天津</span>
								<span>重庆</span>
								<span>成都</span>
								<span>香港</span>
							</p>
						</div>
						<div class="present_all">
							<span class="title_city">其他城市：</span>
							<div class="other_city ">					
								<p>
								<span>上海</span>
								<span>北京</span>
								<span>深圳</span>
								<span>杭州</span>
								<span>武汉</span>
								<span>杭州</span>
								<span>天津</span>
								<span>成都</span>
								<span>广州</span>
								<span>重庆</span>
								<span>苏州</span>
								</p>
								<p>
								<span>南京</span>
								<span>西安</span>
								<span>宁波</span>
								<span>青岛</span>
								<span>长沙</span>
								<span>贵阳</span>
								<span>合肥</span>
								<span>昆明</span>
								<span>济南</span>
								<span>石家庄</span>
								</p>
								<p>
								<span>郑州</span>
								<span>厦门</span>
								<span>无锡</span>
								<span>南宁</span>
								<span>常州</span>
								<span>南昌</span>
								<span>香港</span>
								<span>哈尔滨</span>
								</p>
								<p>
								<span>沈阳</span>
								<span>绍兴</span>
								<span>潍坊</span>
								<span>大连</span>
								<span>宜昌</span>
								<span>长春</span>
								<span>佛山</span>
								<span>包头</span>
								<span>珠海</span>
								<span>南通</span>
								</p>
								<p>
								<span>中山</span>
								<span>东莞</span>
								<span>兰州</span>
								<span>海口</span>
								<span>呼和浩特</span>
								<span>江门</span>
								<span>银川</span>
								<span>河源</span>
								<span>澳门</span>
								<span>株洲</span>
								</p>
								<p>
								<span>惠州</span>
								<span>泰州</span>
								<span>金华</span>
								<span>丽水</span>
								<span>马鞍山</span>
								<span>泉州</span>
								<span>西宁</span>
								<span>扬州</span>
								<span>黄冈</span>
								<span>嘉兴</span>
								</p>
								<p>
								<span>廊坊</span>
								<span>台州</span>
								<span>唐山</span>
								<span>徐州</span>
								<span>大同</span>
								<span>桂林</span>
								<span>柳州</span>
								<span>温州</span>
								<span>芜湖</span>
								<span>宜春</span>
								</p>
								<p>
								<span>蚌埠</span>
								<span>荆州</span>
								<span>烟台</span>
								<span>黔南</span>
								<span>秦皇岛</span>
								<span>遵义</span>
								<span>承德</span>
								<span>洛阳</span>
								<span>绵阳</span>
								<span>莆田</span>
								</p>
								<p>
								<span>三亚</span>
								<span>汕头</span>
								<span>岳阳</span>
								<span>张家口</span>
								<span>淄博</span>
								<span>阿坝</span>
								<span>鞍山</span>
								<span>安庆</span>
								<span>保定</span>
								<span>北海</span>
								</p>
								<p>
								<span>本溪</span>
								<span>滨州</span>
								<span>昌吉</span>
								<span>鄂尔多斯</span>
								<span>抚顺</span>
								<span>广安</span>
								<span>邯郸</span>
								<span>菏泽</span>
								<span>红河</span>
								<span>湖州</span>
								</p>
								<p>
								<span>黄石</span>
								<span>济宁</span>
								<span>焦作</span>
								<span>乐山</span>
								<span>丽江</span>
								<span>凉山</span>
								<span>萍乡</span>
								<span>三门峡</span>
								<span>上饶</span>
								<span>韶关</span>
								</p>
								<p>
								<span>台北</span>
								<span>泰安</span>
								<span>文山</span>
								<span>乌海</span>
								<span>乌鲁木齐</span>
								<span>咸阳</span>
								<span>湘潭</span>
								<span>邢台</span>
								<span>盐城</span>
								<span>云浮</span>
								</p>
								<p>
								<span>肇庆</span>
								<span>镇江</span>
								<span>境外</span>
								</p>
							</div>
						</div>
					</div>
				</div>
				<span class="nav-text1">首页</span>
				<span class="nav-text2">分类</span>
				
			</div>
			<div class="nav-center">
					<img src="imgs/search.png" width="17px"/>
					<input type="text" name="search" id="search" placeholder="搜索明星、演出、体育赛事" value="" />
					<div type="button" class="search-btn" onclick="ss()">搜&nbsp;索</div>
			</div>
			<div class="nav_right">
				<div class="nav-right-left">
					<span><img src="imgs/register.png" alt=""></span>
					<span class="enter_left">登录</span>
					<div class="login-sub">
					<span><img src="imgs/bignum.png" alt="bignum"></span>
						<div class="login-sjx">
						<a href="#">个人信息</a>
						<a href="#">账号设置</a>
						<a href="#">订单管理</a>
						</div>
					</div>
				</div>
				<div class="nav_right_center">
					<span><img src="imgs/phone.png" alt=""></span>
					<span class="enter_left">登录</span>
					<div class="login_ewm">
					<span><img src="imgs/bignum.png" alt="bignum"></span>
						<img src="imgs/code.png" alt="code">
					</div>
				</div>
				<div class="nav_right_right">
					<span><img src="imgs/EN.png" alt=""></span>
					<span class="enter_left">English</span>
				</div>
			</div>
		</div>
	</div>
	<div class="cl"></div>
	<!-- 轮播图 -->
	<div class="slideshow_box">
		<div class="banner">
			<img src="imgs/slideshow1.jpg" alt="slideshow1" onclick="window.location.href='https://detail.damai.cn/item.htm?spm=a2oeg.search_category.recommend.1.295f4d15V5fVcs&id=588347205587&clicktitle=2019%E5%BC%A0%E6%9D%B0%E3%80%90%E6%9C%AA%C2%B7LIVE%E3%80%91%E5%85%A8%E7%90%83%E5%B7%A1%E5%9B%9E%E6%BC%94%E5%94%B1%E4%BC%9A%20%E9%95%BF%E6%B2%99%E7%AB%99'">
			<img src="imgs/slideshow2.jpg" alt="slideshow1" onclick="window.location.href='https://piao.damai.cn/176127.html?pos=2&acm=201808136-2.1003.2.5551476&scm=1003.2.201808136-2.OTHER_1551361610746_5551476?spm=a2oeg.home.banner.ditem_1.591b23e1cCVHb7&clicktitle=%E6%AD%A6%E6%B1%89%E9%99%88%E7%BB%AE%E8%B4%9E'">
		</div>
		<div class="prev">&lt;</div>
		<div class="next">&gt;</div>
		<ul>
			<li class="circle"></li>
			<li class="circle"></li>
		</ul>
	</div>
	<!-- 导航条读取数据 -->
	<div class="nav_list">
		<a href="" class="list1">
			<span class="small span1"></span>
			<p>演唱会</p>
		</a>
		<a href="" class="list2">
			<span class="small span2"></span>
			<p>话剧歌剧</p>
		</a>
		<a href="" class="list3">
			<span class="small span3"></span>
			<p>体育</p>
		</a>
		<a href="" class="list1">
			<span class="small span4"></span>
			<p>儿童亲子</p>
		</a>
		<a href="" class="list2">
			<span class="small span5"></span>
			<p>展览休闲</p>
		</a>
		<a href="" class="list3">
			<span class="small span6"></span>
			<p>音乐会</p>
		</a>
		<a href="" class="list1">
			<span class="small span7"></span>
			<p>曲苑杂坛</p>
		</a>
		<a href="" class="list2">
			<span class="small span8"></span>
			<p>舞蹈芭蕾</p>
		</a>
		<a href="" class="list3">
			<span class="small span9"></span>
			<p>二次元</p>
		</a>
		<a href="" class="list1">
			<span class="small span10"></span>
			<p>旅游展览</p>
		</a>
	</div>

	<!-- 演唱会、、模块 -->
	<div class="content">
		<div class="dm-content concert">
			<div class="head">
				<span class="head-title"></span>
				<a href="" class="more"><span class="head-more">查看全部</span></a>
			</div>
			<div class="box">
				<!-- <a href="" class="box-left">
					<img src="" alt="" class="box-left-bg">
					<div class="box-left-info">
						<div class="title"></div>
						<div class="details">
							<span>起</span>
						</div>
					</div>
				</a> -->
				<!-- <div class="box-right">
					<a href="" class="box-right-item">
						<div class="iteming">
							<img src="" alt="">
						</div>
						<div class="iteminfo">
							<div class="title"></div>
							<div class="venue"></div>
							<div class="showtime"></div>
							<div class="price">
								<span>起</span>
							</div>
						</div>
					</a>
				</div> -->
			</div>
		</div>
		<div class="dm-content opera">
			<div class="head">
				<span class="head-title"></span>
				<a href="" class="more"><span class="head-more">查看全部</span></a>
			</div>
			<div class="box"></div>
		</div>
		<div class="dm-content sports">
			<div class="head">
				<span class="head-title"></span>
				<a href="" class="more"><span class="head-more">查看全部</span></a>
			</div>
			<div class="box"></div>
		</div>
	</div>
	<!-- footer -->
	<div class="footer">
		<div class="ft-content">
			<ul class="ft-links">
				<li class="ft-links-list">
					<a href="https://help.damai.cn">帮助中心</a>
				</li>
				<li class="ft-links-grep">|</li>
				<li class="ft-links-list">
					<a href="https://help.damai.cn/helpPage.htm?pageId=69&amp;categoryId=30">公司介绍</a>
				</li>
				<li class="ft-links-grep">|</li>
				<li class="ft-links-list">
					<a href="https://help.damai.cn/helpPage.htm?pageId=70&amp;categoryId=30">品牌识别</a>
				</li>
				<li class="ft-links-grep">|</li>
				<li class="ft-links-list">
					<a href="https://help.damai.cn/helpPage.htm?pageId=72&amp;categoryId=30">公司大事记</a>
				</li>
				<li class="ft-links-grep">|</li>
				<li class="ft-links-list">
					<a href="https://help.damai.cn/helpPage.htm?pageId=40&amp;categoryId=14">协议及隐私权政策</a>
				</li>
				<li class="ft-links-grep">|</li>
				<li class="ft-links-list">
					<a href="https://jubao.alibaba.com/internet/readme.htm?spm=a2o6e.search.0.0.72f44d15Votov6&amp;site=damai">廉正举报</a>
				</li>
				<li class="ft-links-grep">|</li>
				<li class="ft-links-list">
					<a href="https://help.damai.cn/helpPage.htm?pageId=58&amp;categoryId=5" target="_blank" data-spm="flink6">联系合作</a>
				</li>
				<li class="ft-links-grep">|</li>
				<li class="ft-links-list">
					<a href="https://job.alibaba.com/zhaopin/positionList.htm?keyWord=JXU1OTI3JXU5RUE2&amp;_input_charset=UTF-8">招聘信息</a>
				</li>
				<li class="ft-links-grep">|</li>
				<li class="ft-links-list">
					<a href="https://x.damai.cn/markets/special/fangzhapian?spm=a2o6e.home.0.0.75df48d3hqGWGD&amp;wh_ttid=pc">防骗秘籍</a>
				</li>
			</ul>
			<div class="ft-ft">
				<div class="ft-l">
					<a href="https://www.damai.cn/?spm=a2o6e.home.0.0.591b48d3QzpG8B" class="ft-l-logo">
						<img src="imgs/ft-l-logo.png" alt="">
					</a>
					<div class="ft-l-codebox">
						<img src="imgs/code.png" alt="" class="code">
						<span>APP下载</span>
					</div>
				</div>
				<div class="ft-r">
					<div class="ft-r-contact">
						<a href="https://online.damai.cn/alime/index?from=damai_pc_item&v=3" class="ft-r-contact-btn" style="margin-left: 0;">在线客服</a>
					</div>
					<ul class="ft-r-words">
						<li class="ft-certifivate">
							<a href="http://www.miitbeian.gov.cn?spm=a2o6e.home.0.0.5b4d48d3mVzb2Z">京ICP证031057号</a>
						</li>
						<li class="ft-grep">|</li>
						<li class="ft-certifivate">
							<a href="http://www.miitbeian.gov.cn">京ICP备11043884号</a>
						</li>
						<li class="ft-grep">|</li>
						<li class="ft-certifivate">
							<a href="http://www.beian.gov.cn/portal/registerSystemInfo?recordcode=11010502037341">京公网安备11010502037341号</a>
						</li>
						<li class="ft-grep">|</li>
						<li class="ft-certifivate">
							<a href="imgs/license.jpg">广播电视节目制作经营许可证(京)字第02253号</a>
						</li>
					</ul>
					<ul class="ft-r-words">
						<li class="ft-certifivate">
							<a href="imhgs/1111.jpg">网络文化经营许可证
                        京网文[2016]3438-413号</a>
						</li>
						<li class="ft-grep">|</li>
						<li class="ft-certifivate">
							<a href="imgs/2222.jpg">营业性演出许可证
                        京市演587号</a>
						</li>
					</ul>
					<ul class="ft-r-words">
						<li class="ft-certifivate">北京红马传媒文化发展有限公司 版权所有</li>
						<li class="ft-certifivate">
							<a href="https://www.damai.cn/?spm=a2o6e.home.0.0.591b48d3QzpG8B">大麦网</a>
						</li>
						<li>Copyright 2003-2018 All Rights Reserved</li>
					</ul>
					<ul class="ft-r-words">
						<li>举报投诉邮箱：damai_tousu@member.alibaba.com</li>
					</ul>
					<div class="ft-r-img">
						<a href="#"><img src="imgs/one.gif" alt="" width="120" height="30"></a>
						<a href="https://img.alicdn.com/tfs/TB1CChlpwDqK1RjSZSyXXaxEVXa-1200-1672.jpg"><img src="imgs/two.png" alt="" width="122" height="30"></a>
						<a href="https://www.pcisecuritystandards.org/"><img src="imgs/three.png" alt="" width="49" height="30"></a>
						<a href="http://www.itrust.org.cn/home/index/itrust_certifi/wm/1756737221"><img src="imgs/four.png" alt=""></a>
						<a href="https://search.szfw.org/cert/l/CX20130327002367002885"><img src="imgs/five.png" alt="" width="85" height="30"></a>
					</div>
				</div>
			</div>
		</div>
	</div>
	<!-- 右侧固定定位 -->
	<div class="sidebar">
		<div class="item">
			<a href="https://passport.damai.cn/login" class="alime">
				<div class="icon service"></div>
				<p>在线客服</p>
			</a>
		</div>
		<div class="item middle" style="border-bottom-width: 1px;">
			<a href="https://online.damai.cn/alime/index?from=damai_pc_item&v=3" class="alime">
				<div class="icon damai"></div>
				<p>APP下载</p>
				<div class="qrcode">
					<img src="imgs/code.png" alt="" width="72" height="72">
				</div>
			</a>
		</div>
		<div class="item go-top" style="border-bottom-width: 0;">
			<div class="icon gotop"></div>
			<p>回到顶部</p>
		</div>
	</div>
</body>

<script>

$(function(){//入口函数

	//九大分类传入cid，链接分类页
	function getCid(cid,classname){
		$.ajax({
			url:"http://47.99.153.121:8021/index.php/index/details/typeId/"+cid,
			type:"get",
			dataType:"json",
			success:function(res){
				//链接分类页，html名称放在a的href里面
				var href="damai.html?cid="+cid;
				$(".nav_list ."+classname).attr("href",href);
			}
		})
	}
	getCid(1,"list1")
	getCid(2,"list2")
	getCid(3,"list3")
	getCid(1,"list4")
	getCid(2,"list5")
	getCid(3,"list6")
	getCid(1,"list7")
	getCid(2,"list8")
	getCid(3,"list9")
	getCid(1,"list10")


	//点击查看更多，链接分类页
	function getMore(cid,classname){
		$.ajax({
			url:"http://47.99.153.121:8021/index.php/index/details/typeId/"+cid,
			type:"get",
			dataType:"json",
			success:function(res){
				//链接分类页，html名称放在a的href里面（和上面的一样）
				var href="damai.html?cid="+cid;
				$(".content ."+classname+" .head .more").attr("href",href);
			}
		})
	}
	getMore(1,"concert")
	getMore(2,"opera")
	getMore(3,"sports")



	//获取板块标题  cname
	function getTitle(titleId,classname){
		$.ajax({
			url:"http://47.99.153.121:8021/index.php/index/types/typeId/"+titleId,
			type:"get",
			dataType:"json",
			success:function(res){
				// console.log(res[0].cname)
				$(".content ."+classname+" .head .head-title").text(res[0].cname);
			}
		})
	}
	getTitle(1,"concert")
	getTitle(2,"opera")
	getTitle(3,"sports")


	
	//获取数据的函数  演唱会、话剧歌剧、体育三个板块
	function getdata(typeId,index,classname){
		$.ajax({
			url:"http://47.99.153.121:8021/index.php/index/details/typeId/"+typeId,
			type:"get",
			dataType:"json",
			success:function(res){
				// console.log(res)
				// console.log(res[0])
				// console.log(res[0].did)
				// console.log(res[1].did)
				// console.log(res[2].did)
				// console.log(res[3].did)

				//链接详情页，html名称放在a的href里面
				var str=`<a href="barley0.html?did=${res[0].did}" class="box-left">
							<img src="${res[index].poster}" class="box-left-bg">
							<div class="box-left-info">
								<div class="title">${res[index].title}</div>
								<div class="details">
									${res[index].price}
									<span>起</span>
								</div>
							</div>
						</a>`;
				$(".content ."+classname+" .box").append(str);	

				$(".content ."+classname+" .box").append("<div class='box-right'></div>");
				for(var i=1;i<7;i++){

					// console.log(res[i].did)
					
					//链接详情页，html名称放在a的href里面（和上面的一样）
					var str0=`<a href="barley0.html?did=${res[i].did}" class="box-right-item">
								<div class="iteming">
									<img src="${res[i].poster}" alt="">
								</div>
								<div class="iteminfo">
									<div class="title">${res[i].title}</div>
									<div class="venue">${res[i].address}</div>
									<div class="showtime">${res[i].releasetime}</div>
									<div class="price">
										${res[i].price}
										<span>起</span>
									</div>
								</div>
							</a>`;

					$(".content ."+classname+" .box .box-right").append(str0);
				}
			}
		})
	}
	getdata(1,0,"concert");
	getdata(2,0,"opera");
	getdata(3,0,"sports");

	


	//回到顶部
	$(window).scroll(function(){
		var offsetHeight = document.documentElement.offsetHeight;
		// console.log(offsetHeight)
		var clientHeight = document.documentElement.clientHeight;
		// console.log(clientHeight)
		var scrollTop = document.documentElement.scrollTop;
		// console.log(scrollTop)
		// var scrollBottom = offsetHeight - clientHeight - scrollTop;
		// console.log(scrollBottom)
		if(scrollTop>80){
			$(".sidebar .go-top").show();
			$(".sidebar .go-top").click(function(){
				scrollTo(0,0);
			})
		}else{
			$(".sidebar .go-top").hide();
		}
	})




})//入口函数

		//搜索内容
		function ss(){
			var keyword = $("#search").val();
			// console.log(key);
			keyword = keyword.trim();
			if(keyword ==""){
				alert(" 请输入关键字")
			}else{
				//传递搜索关键字
				window.location.href = "index2.html?keyword="+keyword;
			}
		}
</script>

</html>